The Common Public Radio Interface (CPRI) specification is used for an interface between a radio equipment control (REC) unit and a radio equipment (RE). The interface is an internal interface and is used at a physical layer and a data link layer. For ease of understanding, a CPRI may be abstracted as a periodic data channel. As shown in FIG. 1, FIG. 1 is a data channel whose CPRI period is 6, that is, there are 6 pieces of data within each CPRI period. In an actual application, a CPRI period of a 10 Gigabit (G) data channel is 128, and a CPRI period of a 20G data channel is 320. Similar to Ethernet switching, CPRI switching is an important part of a communications network topology that includes a CPRI. In an actual application, to complete a communications network topology that includes a CPRI, CPRI switching needs to be implemented.
An existing solution is directly performing switching according to a switching relationship table.
In the existing solution, switching is directly performed according to a switching relationship table. Because the switching relationship table is arbitrary, a situation in which an input port distributes data to all output ports at a same moment needs to be considered. In this case, a CPRI switching architecture design in the existing solution is complex, a quantity of ports is limited, and it is hard to implement it at a backend.